-- GENERATED SPELL FOR [Time-Lost Skettis Reaver] --


function spell0_21651(pUnit, Event) --@Battle Shout,Self--
pUnit:FullCastSpellOnTarget(42247,pUnit)
pUnit:RegisterEvent('Sorts_21651', 513, 1)
end

function spell1_21651(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15496,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21651', 641, 1)
end

function spell2_21651(pUnit, Event) --@Frenzy,Self--
pUnit:FullCastSpellOnTarget(3019,pUnit)
pUnit:RegisterEvent('Sorts_21651', 15000, 1)
end

function Sorts_21651(pUnit, Event)
local choix_sorts_21651 = math.random(0, 2)
if choix_sorts_21651 == 0 then
pUnit:RegisterEvent('spell0_21651', 1, 1)
end
if choix_sorts_21651 == 1 then
pUnit:RegisterEvent('spell1_21651', 1, 1)
end
if choix_sorts_21651 == 2 then
pUnit:RegisterEvent('spell2_21651', 1, 1)
end
end

function mob21651_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_21651', math.random(1500, 3000), 1)
end

function mob21651_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21651_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21651_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(21651, 1, 'mob21651_Action')
RegisterUnitEvent(21651, 2, 'mob21651_Leave')
RegisterUnitEvent(21651, 3, 'mob21651_Kill')
RegisterUnitEvent(21651, 4, 'mob21651_Die')
